<?php
session_start();
$user = $_SESSION['user'];
if ($user != ""){
    $hide = "hide";
}
if(isset($_COOKIE['logincheck'])){
    $checkarr = unserialize($_COOKIE['logincheck']);
    //var_dump($checkarr["user"]);
    $iuser = $checkarr['user'];
    $ipsw = $checkarr['psw'];
    $icheck = $checkarr['check'];
}else{
    $icheck = "";
}

require "template/head.html";
if (empty($_GET) || $_GET['action'] == "index"){
        for ($i=1;$i<=10;$i++){
            include "template/contant.html";
        }
}else{
if ($_GET['action'] == "login"){
    include "template/login.html";
}
if ($_GET['action'] == ""){
    include "template/contant.html";
}
if ($_GET['action'] == "show"){
    if (!isset($_COOKIE['logintoken'])){
        echo "<script>alert('您的体验时间已经结束!')</script>";
    }else{
        echo "我是教程";
    }
}
}
require "template/foot.html";
?>
